In search services, users can get information more conveniently by reading the succinct answers to their questions. This paper introduces a feature-based method for the query-focused summarization to extract the answer summary of a user query. A convolutional neural network (CNN) is used to learn the semantic representation of a sentence, by which the similarity between a candidate answer sentence and a user query is evaluated. The neural network is trained under the framework of max-margin learning. Experiments in Baidu Knows verify that the proposed method can generate the concise answer of a user query.